Learning Objectives

After completing this lesson, you'll be able to:

Video

Note

Videos are provided in this course if you prefer to watch instead of reading the text below. Note that some Quiz answers might require you to read the text.

Manage Your Attributes

When FME reads data, each feature type is read with a set of user-defined attributes. Each attribute is defined by its name, data type, width, and number or decimal places.

Note

Learn more about how FME handles schema.

A high proportion of the top 30 transformers are support transformers for managing attributes. These create new attributes, rename them, set values, and delete them.

A key use for these transformers is to rename attributes for schema mapping.

The main attribute-management tasks and the transformers that can be used are as follows:

Task Transformers
Create Attributes AttributeCreator, AttributeManager
Set Attribute Values AttributeCreator, AttributeManager
Remove Attributes AttributeKeeper, AttributeManager, AttributeRemover, BulkAttributeRemover
Rename Attributes AttributeManager, AttributeRenamer, BulkAttributeRenamer
Copy Attributes AttributeCopier, AttributeCreator, AttributeManager
Sort Attributes AttributeManager
Change Attribute Case BulkAttributeRenamer
Add Prefixes/Suffixes BulkAttributeRenamer
Note

Don't misunderstand the BulkAttributeRenamer. It changes the case - or adds suffixes/prefixes - to the attribute namenot the attribute value.

Many of these transformers can carry out similar operations, and you can see that the AttributeManager does so many tasks you can use it almost exclusively.

However, it's important to note that the AttributeManager is a general-purpose tool. Using transformers with more specific functions, e.g., the AttributeRenamer, can offer a performance boost. The only time AttributeManager tends to be faster than individual function attribute transformers is when you need to undertake many different attribute transformations in a row. Then the AttributeManager is more performant.

Note

See this blog post by FME user Aurélien Chaumet for more information on attribute transformer performance.

For further reading check out this article on Attribute Management on the Safe Software blog.